/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Behavioral.Iterator;

import java.util.Iterator;

/**
 *
 * @author Demoni
 */
public class test {
    public static void main(String args[]){
        
        Carrera c = new Carrera("Analista");
        c.add("Alumno1");
        c.add("Alumno2");
        
        Iterator<Alumno> iter = c.iterator();
        while (iter.hasNext()){
            Alumno a = (Alumno) iter.next();
            a.print();
        }
    }
}
